<?php
session_start();
include_once  dirname(__FILE__).'./../../../module/common/config.inc.php';
//if (!$login){ include_once 'limit.php'; }
include_once SITE_ROOT.'module/common/db_mysql.inc.php';
include_once SITE_ROOT.'lib/smarty/Smarty.class.php'; //包含smarty类文件
$t = new Smarty();  //建立smarty实例对象$smarty
$t->template_dir = SITE_ROOT.'theme/admin/static/';
$t->compile_dir  = SITE_ROOT.'theme/templates_c/';
$t->compile_id = 'admin_static';
//$t->cache_dir = WEB_ROOT.'admin/_cache/';
$t->caching      = false;
$t->left_delimiter 	= "{{";
$t->right_delimiter = "}}";

$outvar[img_url] = '../theme/admin/images/';
$outvar[js_url] = '../theme/admin/javacript/';
$outvar[site_title] = SITE_NAME;
$outvar[filename] = $php_self_name;

function outFile($mainT='main'){
	global $t,$outvar;
	if ($_SESSION[showtips]){
		$outvar[showtips] = $_SESSION[showtips];
		$_SESSION[showtips] = '';
	}
	assignMore($outvar);
	$t->display($mainT.'.html');
}
